import numpy as np
import matplotlib.pyplot as plt
import math
from mpl_toolkits.mplot3d import Axes3D
# import plt2d
import plt3d


if __name__ == '__main__':

    # # (x, y)
    # point2d = (.1, .2)
    # plt2d.plt_point2d(point2d)
    # # (x, y, w)
    # point2d_w1 = (.1, .2, .3)
    # plt2d.plt_point2d_wave(point2d_w1)
    # point2d_w2 = (.2, .1, .3)
    # plt2d.plt_point2d_wave(point2d_w2)
    # # l = (a, b, c) x.l = ax + by + c
    # line1 = (.1, .3, .1)
    # plt2d.plt_line(line1)
    # line2 = (.2, .1, .1)
    # plt2d.plt_line(line2)
    #
    # cross = plt2d.find_cross(line1, line2)
    # plt2d.plt_point2d_wave(cross)
    #
    # line_w = plt2d.make_line(point2d_w1, point2d_w2)
    # plt2d.plt_line(line_w)
    #
    # line3 = (.0, .3, .4)
    # plt2d.plt_line(line3)
    # # l = (cos(theta), sin(theta),d)
    # # line4 = (math.pi/4, .1)
    # # plt_line_theta(line4[0], line4[1])
    # # line5 = (-math.pi / 2, -.1)
    # # plt_line_theta(line5[0], line5[1])
    # line6 = (-math.pi/3, .2)
    # plt2d.plt_line_theta(line6[0], line6[1])
    #
    # # 设置坐标轴范围
    # # plt.xlim((-1.2, 1.2))
    # # plt.ylim((-1.2, 1.2))
    # # 设置坐标轴名称
    # plt.xlabel('X')
    # plt.ylabel('Y')
    # # 设置坐标轴刻度
    # # my_x_ticks = np.arange(-1.2, 1.2, 0.2)
    # # my_y_ticks = np.arange(-1.2, 1.2, 0.2)
    # # plt.xticks(my_x_ticks)
    # # plt.yticks(my_y_ticks)
    # # 格子
    # plt.grid(True)

    plt.show()

